Liquid measuring system and methods

ABSTRACT

Ultrasonic apparatus determines the fluid depth, volume, and temperature in a storage tank. A system description for monitoring an underground storage tank containing gasoline is described. The system determines the water&#39;s and gasoline&#39;s depth, volume, and temperature. The apparatus consists of a remote console, ultrasonic probe, and interconnecting cable. The remote console contains a display to report tank information and a computer to operate the probe. The probe consists of an ultrasonic transducer above the bottom of the probe facing upwards to transmit and receive ultrasonic signals, vertically spaced reflectors and a temperature sensor to measure fluid temperature.

This is a divisional of an application under 35 CFR 1.60, of pendingprior application Ser. No. 08/401,874, filled on Mar. 10, 1995 forLIQUID MEASURING SYSTEM AND METHODS, now U.S. Pat. No. 5,765,433.

BACKGROUND OF THE INVENTION

This invention relates generally to the measuring of the volume ofliquid in a tank using ultrasound, and, in particular, relates to themeasuring of the volume of liquid in underground fuel storage tanks.

Many liquids are stored in tanks where the volume of the liquid in thetank cannot be directly observed. In many instances, the liquids arefuels such as gasoline and the tanks are large underground tanks. In thepast a very common way of determining the volume in such a tank was toinsert a calibrated rod and read the height of the liquid from the lineformed on the rod by the liquid surface. This method, however, is notvery precise and there are inherent errors in utilizing such anapproach. One very serious drawback of the lack of precision is theinability to detect the loss of gasoline due to leakage. It is readilyapparent that a leakage of gasoline or fuel from underground tanks cancause substantial environmental problems. It is desirable to detect suchleaks before the problems become severe. Furthermore, state and federalregulations are beginning to mandate requirements for the detection offuel leakage.

Currently, the EPA requires underground storage tanks to undergo leaktests. The EPA requires the tanks to be checked monthly with a systemcapable of detecting a 0.2 gallons per hour leak or yearly with a systemcapable of detecting a 0.1 gallons per hour leak. Systems presently onthe market generally measure depth changes of less than 0.001 inches andtemperature changes of less than 0.001° C.

The market is extremely price sensitive because tank owners desire tocomply with regulations at minimal expense. Liquid measuring systemswhich utilize magnetostrictive and ultrasonic probes are the mostpopular in the market today. Magnetostrictive probes are higher pricedgiving ultrasonic probes a price advantage. Thus, it is desirable toprovide an ultrasonic system.

Systems are now available which utilize ultrasonic transducers andultrasound to determine the volume of liquid and typically place thetransducer at the end of a probe and insert the probe into the fueltank. The probe typically includes reflectors spaced along its length atprecisely known distances from the transducer.

In one such known arrangement, the reflectors appear on the outsidesurface of the probe and are equally spaced apart. In operation, such aprior art system periodically transmits bursts of ultrasonic energy fromthe transducer. The burst of sonic energy produces echoes off of each ofthe submerged reflectors and off of the liquid/air surface interface.The echo received from the surface is typically the strongest echobecause the large surface area reflects a greater amount of energy thanwould any of the reflectors positioned on the probe. The transmittedburst typically includes several ringing cycles. The echo signalwaveforms likewise includes several ringing cycles. In the prior system,a receiver sensitivity is initially set at a minimum value and issuccessively increased until an echo signal is received. From thatpoint, a series of echoes are analyzed in order to identify the firstcycle in the echo signal waveform. Once the first cycle has beenidentified, it is used as a reference point to determine the echo delaytimes. The system then proceeds through an algorithm to identify everysubmerged reflector with the goal of identifying the topmost submergedreflector. When the topmost submerged reflector is identified, the echodelay time from the topmost reflector is utilized to calculate anaverage sonic velocity through the fuel. Based upon this average sonicvelocity and the echo time received from the surface of the fuel, thedepth of the liquid in the tank is calculated.

In addition, many approaches have been utilized to compensate forvariations in the volume of the liquid with temperature. Again, in theprior above identified system, a temperature reading is taken at a pointnear the ultrasonic transducer. The sonic velocity between thetransducer and the lowest reflector is measured to produce a referencesonic velocity at a reference temperature. The prior systems thenproceed to determine an average temperature directly from the averagesonic velocity in the liquid. The calculated volume of liquid in thetank is then adjusted to compensate for the temperature which isdetermined from the change in the average sonic velocity.

Still a further desirable aspect of any such measuring or gauging systemis to accurately determine the depths of water in the fuel tank. In theprior system, the transducer is suspended in the tank such that it wouldbe above the fuel/water interface. By relying upon multiple reflectionof the ultrasonic energy from the transducer to the fuel/air interfaceback to the water/fuel interface and reflected back to the fuel/airinterface and back to the transducer, the level of the water in the tankwould be calculated.

The present invention is directed to providing an improved ultrasonicapparatus for measuring and remotely displaying the amount of liquid ina tank that provides for significantly improved accuracy in determiningthe volume and significantly improved accuracy in determining atemperature compensated volume and further, more accurately measuringthe volume of water in a tank so that the volume of fuel can be moreaccurately calculated.

SUMMARY OF THE INVENTION

In accordance with the principles of this invention, an ultrasonicmeasuring system for measuring the amount of liquid in a tank has beendeveloped. This system utilizes a probe which is inserted into a fueltank and which carries at its lower end an ultrasonic transducer. Thetransducer is positioned to be at the bottom of the fuel tank andtransmits ultrasonic energy upward into the liquid. The ultrasonictransducer receives echoes and from those echoes determines the heightof liquid in the tank with a high degree of accuracy.

In accordance with the principles of this invention, the depth of theliquid in the tank is determined by measuring the echo delay time fromthe topmost submerged reflector to the transducer and the next topmostsubmerged reflector to the transducer. From these two measurements, theaverage sonic velocity in the strata of the tank immediately adjacent tothe topmost strata is determined. The difference in the echo delay timebetween the signal received from the fuel/air surface and the topmostsubmerged reflector is combined with the average sonic velocity of thestrata determined as set forth above to determine the height of the fuelabove the topmost submerged reflector. To this distance is added theprecisely known distance from the bottom of the tank to the topmostsubmerged reflector. With this arrangement, a very precise determinationof the depth of the liquid in the tank is made.

Further in accordance with the invention, once the depth of liquid inthe tank is precisely determined, the average sonic velocity in the tankmay be calculated and the system operated in a mode in whichmeasurements may be taken solely of the echo delay time between theliquid/air interface and the bottom of the tank and utilizing thesemeasurements in combination with the calculated average sonic velocity,the depth of the liquid may be determined and from the depth, thevolume.

Further in accordance with another aspect of the invention, thecalculated volume of liquid in the tank is compensated according totemperature variations. The temperature compensation is, however,performed over strata in the tank. The strata are determined by pairs ofreflectors. In accordance with the invention, the change in sonicvelocity between pairs of reflectors is utilized to determine the changein temperature from an earlier measurement and the strata between thepair of reflectors. The change in temperature for a strata is thenutilized to determine a temperature corrected volume for the strata. Thesummation of the temperature corrected volumes for the various strata inthe tank provide for a temperature compensated volume.

Still further in accordance with the invention, a highly accurate methodis used to precisely identify corresponding portions in the echowaveforms. In accordance with the invention, a profiling of thecharacteristics of the echo signals from the various reflectors and thefuel/air interface is conducted. During this profiling operation, thepeak amplitudes of the reflected echo signals are measured and thelargest range in magnitude between cycle peaks in the waveform receivedare determined. The objective is to identify that portion of thereflected waveform which has the largest magnitude of swing above thepeak of other portions of the waveform.

Still further in accordance with the invention, it has been found thatthe positioning of reflectors within the probe is advantageous. Inaddition, it has been found to be advantageous to have the reflectors onthe probe spaced apart not equidistant but at distances which areequivolumetric. For a tank of generally circular cross section, thedistances between reflectors which are closer to the middle of the tankwould therefore be closer than the distances between reflectors closerto the top and bottom of the tank.

BRIEF DESCRIPTION OF THE DRAWINGS

The invention will be better understood from a reading of the followingdetailed description of a preferred embodiment in which:

FIG. 1 illustrates the application of the present invention to agasoline service station having an underground fuel tank positioned at alocation remote from that of the service attendant;

FIG. 2 illustrates in block diagram form the system shown in FIG. 1;

FIG. 3 illustrates a probe of the type utilized in the presentinvention;

FIG. 4 illustrates a signal waveform;

FIG. 5 illustrates in flow chart form the operation of the system in theprofiling mode;

FIG. 6 illustrates in flow chart form one aspect of system operation;

FIG. 7 illustrates in flow chart form a second aspect of the system; and

FIG. 8 illustrates in flow chart form a third aspect of systemoperation.

DETAILED DESCRIPTION

Turning now to FIG. 1, a typical underground fuel tank installation at agasoline service station is shown. The tank is only about one half fulland the surface or fuel/air interface 180 of the fuel 190 is shown.Typically, fuel tanks will also contain water 175 from condensation.Because of the different densities, the water will be at the bottom ofthe tank. A fuel/water interface 170 occurs as a result. The undergroundfuel tank 110 has extending upwardly there-from a riser 111 whichterminates in a containment box 112. At the upward end of the riser 111,a riser cap 113 is provided. In a typical arrangement utilized atservice stations, the riser 111 and riser cap 113 may form part of aStage one vapor recovery system. In such systems, during the refuelingof the underground tank, a vapor recovery hose is connected between thefuel truck and a vapor recovery vent on the fuel tank, in addition tothe fuel hose which is connected between the fuel truck and the fillriser (which is not shown in the drawing) on the underground tank. Whilefuel is loaded into the tank via the fuel hose, the tank vapors arerouted back to the fuel truck via the vapor recovery vent and the hoseconnection to the truck. Thus the riser cap 113 is removed duringrefueling to permit connection to the vapor recovery hose.

Supported in the riser is an ultrasonic probe or waveguide 300 which isshown in greater detail in FIG. 3. The probe or waveguide 300 is oftubular form and at its bottom end has affixed thereto a transducermodule 310. The transducer module 310 includes an ultrasonic transducer320, a temperature sensor 340 and a transducer electronics module 330.Both the transducer 320 and the temperature sensor 340 are connected tothe transducer electronics module 330 which in turn is coupled to theconsole circuitry 250 via a three wire cable 350. The details of thetransducer electronics module are disclosed in my copending U.S. patentapplication filed on even date herewith titled Transducer ModuleCircuitry and assigned to a common assignee. The subject matter of thepatent application is specifically incorporated herein.

The probe or waveguide assembly 300 includes calibration reflectors 370positioned within the probe along its inner surface. The reflectors 370are spaced apart at distances which represent equal volumetric segmentsof the fuel tank. In contrast to the probe of this illustrativeembodiment other probe assemblies are known in which the reflectors arespaced apart by equal distances along the length of the probe. It hasbeen found advantageous to have the reflectors 370 which are furtheraway from the transducer 320 to be of longer length to increase the sizeof the reflected signal. Each reflector 370 is flat on its bottom tocreate a maximum echo reflection.

The transducer module 310 is connected to a cable 350 which may be runthrough a conduit 114 as shown in FIG. 1. In some instances, the cable350 is not run through the conduit 114 but rather is directly buried inthe ground. The cable 350 terminates at a remote console 140. The remoteconsole 140 is typically located in a building 150 which may be theservice station building, or a remote building located on the premises.

Although only one underground storage tank 110 is shown in the drawingof FIG. 1, it should be readily apparent to those skilled in the artthat gasoline stations typically have more than one underground fuelstorage tank and the present invention is applicable to arrangementshaving a plurality of underground fuel storage tanks. In thosearrangements an ultrasonic probe 300 in each tank is coupled to theconsole 140.

Turning now to FIG. 2, the remote console 140 includes a user interface241 and a data processor 242. The user interface 241 includes a display243 and may also include a keyboard 244 or a push button arrangement forselection of display information and for controlling the operation ofthe system. The data processor 242 can be a microprocessor or it can bea personal computer of the type well-known in the art. The remoteconsole 140 is utilized to display tank information which is determinedfrom the system. The data processor 242 is utilized to control theoperation of the transducer electronics 250 and to analyze the datasignals received from the transducer module 310 to operate the tankmeasurement system including performing calculations based on the datareceived. The data processor 242 can determine and display the volume offuel in the tank as well as the volume of water in the tank. Inaddition, the system can provide for temperature compensated volumechange measurements. Still further, the system can be utilized toinventory product as well as to detect leakage from the tank at very lowloss rates.

Pulse generator 260 is controlled by the data processor 242 to cause theultrasonic transducer 320 to generate ultrasonic signals in the tank.Because of the potentially explosive environment in the fuel tank, themanner in which the transducer 320 is pulsed must be intrinsicly safe.There are several ways to provide pulse signals to the transducer.However, one particularly advantageous arrangement is disclosed in myaforementioned copending patent application filed on even date herewith.When the transducer 320 is excited by the application of a pulse signal,it produces an output waveform which is a multicycle ringing waveform.When the ultrasonic waveform hits a reflector 370 or the fuel/airinterface 180 or a fuel/water interface 170, an echo or reflectionsignal is generated. The ultrasonic transducer 320 not only responds toan electrical signal to produce an ultrasonic signal waveform, but alsoresponds to the receipt of an ultrasonic waveform to produce acorresponding electrical signal output.

Each echo or reflected signal which is received by the transducer 320 iscoupled via cable 350 to a programmable amplifier 270 which, in turn, issupplied to a comparator 275 which compares the output of the amplifierwith a threshold signal that is determined by digital to analogconvertor 276 which is, in turn, controlled by the data processor 242. Atimer 280 is started each time an echo is received and stopped onreceipt of a subsequent echo signal. The comparator 275 is utilized todetermine the time sequence of signals detected by the transducer.

The system probe operation involves many steps. The data processor 242specifies a pulse power and then commands the pulse generator 260 totransmit. The pulse generator 260 drives the ultrasonic transducer 320with a burst of electrical energy that is proportional to the pulselevel. The transducer 320 converts the electrical energy into ultrasonicenergy. An ultrasonic burst travels upward through the tank. Withreference to FIGS. 1 and 3, returning echoes are created by thefuel/water interface 170, fuel/air interface 180, and submergedcalibration reflectors 370. The returning echoes travel downward throughthe fluid. When the returning echoes impact the transducer 320, thetransducer 320 converts the ultrasonic energy back to electrical energy.The gain of amplifier 270 may be varied in steps from +5, +10, +30 and+40 and must be adjusted to allow comparator 275 to trigger on thereturning echoes. The data processor 242 adjusts the comparator's 275sensitivity by adjusting the pulse generator's 260 level, programmableamplifier's 270 gain, and/or the threshold voltage produced by digitalto analog convertor 276. When the comparator 275 triggers on an echo,the timer 280 transmits the current time to the data processor 242. Thedata processor 242 records the echo times. The data processor 242 alsoreads the probe's temperature sensor 340. The water and gasoline depth,volume, and temperature are calculated from the measured information.

By positioning the transducer module 310 at the tank bottom, thefuel/water interface is detected when the interface rises abovetransducer 320. In addition, the height of the first reflector up fromthe bottom is chosen to be higher than any normal anticipated waterlevel in the tank.

The water depth, designated as Xw, is calculated by using the measuredfuel/water echo time designated as tw. Because water measurementaccuracy is not critical, a constant speed of sound for water,designated as vw, is used. The depth of water is calculated withXw=vw*tw/2.

The water volume, designated as Vw, is calculated from Xw and the tankmanufacturer's tank chart. The tank chart converts depth amounts tovolume amounts. The tank chart is stored by the data processor 242, andthe data processor interpolates conversions that are between chartpoints.

The gasoline depth, designated by Xz, is calculated by using themeasured air/gasoline echo time, designated as tz, and submergedcalibration reflector echo times designated as ta, tb, tc, etc.

The gasoline volume, designated by Vz, is calculated from Xz in the samemanner as the water volume.

The gasoline temperature, designated by Ttotal, is calculated by usingthe measured air/gasoline echo time, designated as tz, submergedcalibration reflector echo times designated as ta, tb, tc, etc., and themeasured temperature designated as Tt.

When the system is initially powered up, the system will operate in afirst mode of operation which is referred to as the low resolution mode.This initial operation is shown in a flow diagram as FIG. 5. In the lowresolution mode, the system will operate to adjust the transmit signallevel of pulse generator 260 and the receive signal gain of receiveamplifier 270 to capture the largest echo E1. The time at which the echois received is noted as are both the transmit signal level and thereceive gain. Next, the system will look for another echo E2 prior tothe largest echo E1. If echo E2 is detected the echo E2 is from thefuel/water interface and echo E1 is from the fuel/air interface. If echoE2 is not detected, then two determinations are made. First, it isdetermined whether the depth represented by the time of the echo E1represents a depth which is greater than the maximum water depth. Inthis instance, then echo E1 is from the fuel/air interface.Alternatively, if echo E1 is received as a result of utilizing theminimum sensitivity level, then echo E1 is from the fuel/air interface.

If the depth is not greater than the maximum water depth and the minimumsensitivity level was not utilized then the echo validation time, i.e.,the time window during which an echo may be captured (as described inthe preceding paragraph), is increased and the system attempts toidentify an echo E2 after echo E1. If an echo E2 is detected, then echoE2 is from the fuel/air interface and the echo E1 is reflected from thefuel/water interface. If echo E2 is not detected, then the echo E1 isfrom the fuel/air interface. At this time, the system will attempt tooperate in a high resolution mode.

The system may not be able to switch to the high resolution mode if, forexample, the surface of the fuel/air interface is moving during highresolution initialization as it would if the tank is being filled.

Initially, when operating in the high resolution mode, the signal levelof pulse generator 260 determined in the low resolution mode is utilizedas well as the echo validation time window determined in the lowresolution mode for the fuel/air interface and the fuel/water interface.The waveform for the fuel/air interface is now profiled to choose aspecific echo ring to trigger on for the fuel/air echo.

The submerged reflectors are then profiled. To profile the reflectorechoes the threshold of the receiver is set to a minimum value and asignal is transmitted from the transducer. The times of all echoesreceived which are less than the time for the fuel/air interface to bereceived are stored. These times will be the echo times for eachsubmerged reflector. The system will then profile each of the reflectorecho waveforms. If at least two reflectors are identified, then thesystem will operate in the high resolution mode.

As a result of profiling, the pulse generator signal levels are set, thereceive thresholds for each reflector are set and the time windows aredetermined for the fuel/air interface. One hundred measurements are thentaken for the fuel/air depth and the average for these measurements istaken to determine the echo time from the surface. Similarly, onehundred measurements are taken for each submerged reflector andwater/fuel interface and averaged for each. The averaged numbers at thistime are high resolution numbers for each reflector and for the fuel/airinterface.

The high resolution mode is shown in the flow diagram of FIG. 6. Thehigh resolution mode is repeated periodically without going back intothe low resolution mode. No reprofiling occurs during these cycles. Ineach cycle of the high resolution mode the depth of the product in thetank is determined by determining the time difference between thefuel/air interface and the top submerged reflector and multiplying thattime difference by the sonic velocity between the top two submergedreflectors and adding the height of the top submerged reflector. In theevent that an error is detected in any of the operations, such as mightoccur when the tank is being filled, the system will switch to operatein the low resolution mode. In the low resolution mode, the echo timefrom the fuel/air interface is determined and is multiplied by productsound velocity which is determined from a value determined from the lasthigh resolution mode measurements. This value of product sound velocityis calculated from the product depth which was determined as describedabove for the high resolution mode and dividing that depth by the echotime for the fuel/air reflection.

To profile the echo waveform the procedure set forth in FIGS. 7 and 8 isinitially followed.

Initially, the receive threshold of comparator 275 is set to 1.5 voltsvia D/A convertor 276. The gain of amplifier 270 is set to its maximumvalue and the signal level of pulse generator 260 is set to its maximumlevel.

The pulse generator 260 is triggered and transducer 320 generates anultrasonic signal. After an echo is received, using amplifier 270, thereceive gain of amplifier 270 is decreased and is decreased after eachpulse until no echo is received. After no echo is received the gain ofamplifier 270 is increased by one step.

The pulse generator level is then set by a successive approximationtechnique as set forth in FIG. 8.

This system provides an improved method for triggering on ultrasonicechoes. On an initial echo scan, each echo is profiled. The profiledechoes include calibration reflector and gasoline surface echoes. Foreach profiled echo, the amplitudes Ax, Ay, Az of each ring x, y, z inFIG. 4 are measured, the amplitude differences between the measuredamplitudes are computed, and the trigger sensitivity is selected for thelargest computed amplitude difference, e.g., /Ax-Ay/, and that positionof the waveform will be utilized for triggering for that particularecho. On subsequent echo scans, the selected trigger sensitivities areused to trigger on each selected echo rings, and the echo scanning isquick because the echoes are not profiled again. As a result, the echotimes for each echo are reliable and consistent until another echo scaninitialization is required.

In the present invention, the method for determining the liquid depthuses the speed of sound between the last two submerged reflectors 370for measuring the depth. With reference to FIG. 3, the known depths forthe reflectors 370 are designated as Xa through Xg, with Xa being thelower reflector. The measured echo times for the reflectors 370 aredesignated as ta through tg. The calculated depth and measured echo timefor the gasoline are designated as Xz and tz. The ultrasonic systemmeasures tf, tg, and tz. Then Xz is calculated withXz=(Xg-Xf)/(tg-tf)*(tz-tg)+Xg.

In one previous method determines the liquid depth by using the averagespeed of sound Vavg between the transducer and the last submergedreflector. However, Vavg does not accurately represent the speed ofsound between the submerged reflector and the gasoline surface. Speed ofsound changes in the gasoline at lower depths affect Vavg resulting ingasoline depth errors.

The method for determining the gasoline temperature is improved byweighting the temperature in each submerged calibration reflector zoneby the gasoline volume in the zone. The measured temperature at thetransducer is designated as Tt. Assume in this case, four calibrationreflectors are submerged, but at other times the number of submergedcalibration reflectors varies. The known depths for the calibrationreflectors are designated as Xa, Xb, Xc, and Xd. The measured echo timesfor the calibration reflectors are designated as ta, tb, tc, and td. Thecalculated speed of sound between the transducer and the firstcalibration reflector, the first and second calibration reflector, thesecond and third calibration reflector, and third and fourth calibrationreflector are designated as vta, vab, vbc, and vcd. The speeds of soundare calculated with v12=(X2-X1) /(t2-t1)/2). Once the speeds of soundare calculated, they are saved as initial speeds of sound designated asvtai, vabi, vbci, and vcdi. Along with the initial speeds of sound, thetransducer temperature is saved as the initial temperature designated asTti. On subsequent readings, current speeds of sound are calculated. Thecalculated temperature changes are designated as .increment.Tta,.increment.Tab, .increment.Tbc, and .increment.Tcd. The temperaturechanges are calculated with.increment.T12=(v12-v12i)/(.increment.v/.increment.T) where.increment.v/.increment.T is a predetermined constant. The currenttemperatures are calculated with T12 =.increment.T12+Tti. The calculatedtemperatures are designated as Tta, Tab, Tbc, and Tcd. The gasolinevolumes in each calibration reflector zone are designated as Vta, Vab,Vbc, and Vcd. The volume weighted temperature, Tvw, is calculated withTvw=(Tta*Vta+Tab*Vab+Tbc*Vbc+Tcd*Vcd)/ (Vta+Vab+Vbc+Vcd).

A previous method determines the temperature by using the average speedof sound Vavg between the transducer and the last submerged reflector.However, Vavg does not accurately represent the speed sound of thegasoline volume because the volume is not equally distributed along thetemperature measuring axis. Speed of sound changes in tank areas ofsmaller volume are weighted too heavily as compared to tank areas oflarger volume resulting in gasoline temperature change errors. Thus, mymethod obtains a higher accuracy in determining the temperature.

It will be apparent to those skilled in the art that many variations maybe made to the illustrative embodiment of the invention describedwithout departing from the spirit or scope of the invention. Theinvention is to be limited only by the scope of the claims appendedhereto.

What is claimed is:
 1. A method of profiling a waveform of echo signalsreceived by a transducer in an ultrasonic fluid measuring system, saidmethod comprising:measuring the amplitudes of peaks of cycles of saidwaveform; calculating the absolute values of differences of saidamplitudes between adjacent cycles of said waveform; identifying thecycle of said waveform having the largest absolute value difference overan adjacent cycle; and utilizing said identified cycle of said waveformto detect subsequent ones of said echo signals.